Skip to content

Improve video blocker, DEV-1618#45

Merged
iranimij merged 4 commits intomasterfrom
DEV-1618-block-video-until-consent
Feb 6, 2026
Merged

Improve video blocker, DEV-1618#45
iranimij merged 4 commits intomasterfrom
DEV-1618-block-video-until-consent

Conversation

@iranimij
Copy link
Contributor

@iranimij iranimij commented Feb 5, 2026

Note

Medium Risk
Touches both server-side HTML rewriting and PageBuilder widget initialization, so regressions could break video background rendering or leave videos blocked/unblocked incorrectly depending on consent state.

Overview
Extends the video consent blocker beyond iframes to also handle PageBuilder video backgrounds: ExternalVideoReplacer now rewrites data-video-src attributes for YouTube/Vimeo URLs into data-cookieblock-src (and adds data-cookieconsent="marketing" when missing).

On the frontend, adds a new RequireJS mixin for Magento_PageBuilder/js/widget/video-background that swaps data-video-src/data-cookieblock-src, hides the element, and injects/removes the blocker overlay until marketing consent is granted; the slide widget mixin is adjusted to reuse a shared video-platform-validator helper instead of duplicating URL checks.

Written by Cursor Bugbot for commit 3f96e01. This will update automatically on new commits. Configure here.

@iranimij iranimij requested a review from sprankhub February 6, 2026 08:07
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

@iranimij iranimij merged commit 70b89e4 into master Feb 6, 2026
25 of 37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants